<?php

namespace app\forms\role;

use app\forms\Model;

/**
 * 角色 父类 表单
 */
class BaseForm extends Model
{
    public $name;
    public $item;
    public $auth;
    public $data;
    public $remark;

    public function rules()
    {
        return [
            ['name', 'trim'],
            ['name', 'string', 'max' => 32],
            ['name', 'required', 'message' => '名称必填'],

            ['remark', 'trim'],
            ['remark', 'string', 'max' => 64],

            ['item', 'safe'],
            ['auth', 'safe'],
            ['data', 'safe'],
        ];
    }
}